package com.ayx.springcloud.controller;

import com.ayx.springcloud.entities.CommonResult;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.client.RestTemplate;

@RestController
public class OrderController {

    public static final String url = "http://cloud-provider-payment8004";
    @Autowired
    private RestTemplate restTemplate;

    @GetMapping("payment/get")
    public String getOrder(){
        return restTemplate.getForObject(url+"/payment/zk/",String.class);
    }
}
